package com.example.freemarker.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.servlet.ModelAndView;

import java.util.UUID;

/**
 * <p>
 * Hello
 * </p>
 *
 * @author ross zhang
 * @version 1.0
 * @since 2022/4/10 18:25
 */
@RestController
public class HelloController {

    @GetMapping(value = "/hello")
    public ModelAndView hello(ModelAndView modelAndView){
        modelAndView.addObject("msgHello", UUID.randomUUID().toString());

        modelAndView.setViewName("hello");
        return modelAndView;
    }



}
